package com.wangdao.wechatmall.bean.vo.admin;

import java.util.Date;
import java.util.List;

/**
 * @ClassName: AdminCreateVO
 * @Description ${DESCRIPTION}
 * @Author Xinhao Yi
 * @Date 2021/7/9  9:30
 */
public class AdminCreateVO {

    /**
     * id : 29
     * username : Yxh1234
     * password : $2a$10$FrlYZizSgeOhFfd2XngNZu0R6xSWCROoCQttn07vPt/5yoENGP8DG
     * avatar : http://182.92.235.201:8083/wx/storage/fetch/vu0cb1etwbz1rcknmyfj.jpg
     * addTime : 2021-07-09 02:38:44
     * updateTime : 2021-07-09 02:38:44
     * roleIds : [1,2,11]
     */

    private int id;
    private String username;
    private String password;
    private String avatar;
    private Date addTime;
    private Date updateTime;
    private List<Integer> roleIds;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public Date getAddTime() {
        return addTime;
    }

    public void setAddTime(Date addTime) {
        this.addTime = addTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public List<Integer> getRoleIds() {
        return roleIds;
    }

    public void setRoleIds(List<Integer> roleIds) {
        this.roleIds = roleIds;
    }

    public static AdminCreateVO ok(int id,String username,String password,String avatar,Date addTime,Date updateTime,List<Integer> roleIds){
        AdminCreateVO adminCreateVO = new AdminCreateVO();
        adminCreateVO.setId(id);
        adminCreateVO.setUsername(username);
        adminCreateVO.setPassword(password);
        adminCreateVO.setAvatar(avatar);
        adminCreateVO.setAddTime(addTime);
        adminCreateVO.setUpdateTime(updateTime);
        adminCreateVO.setRoleIds(roleIds);
        return adminCreateVO;
    }

}
